<?php

    class jwSocketActions extends sfActions
    {
        public function executeSave()
        {
            if ( $this->getUser()->hasAttribute( 'id', 'socket' ) )
            {
                $content = $this->getRequestParameter( 'content' );
                $socket = jwSocketPeer::retrieveByPK( $this->getUser()->getAttribute( 'id', null, 'socket' ), $this->getUser()->getCulture() );
                $this->forward404Unless( $socket );
                
                $socket->setContent( $content );
                $socket->save();
                return sfView::NONE;
            }
        }
    }
?>